<template>
    <f7-page class="detail">
      <f7-navbar>
        <f7-nav-left>
          <f7-link back icon-material="arrow_back" force></f7-link>
        </f7-nav-left>
        <f7-nav-title>验收修改申请</f7-nav-title>
        <f7-nav-right></f7-nav-right>
      </f7-navbar>
      <div class="content-box">
        <img :src="require(`../../../../assets/img/qzjx/${'TSQZJ'}.png`)" alt="" class="left-box" />
        <div class="right-box">
          <div class="title-box">
            <section>
              <h3>粤A 123456</h3>
              <span class="tag tag-fill">自编号：#2</span>
            </section>
          </div>
          <p>五号线TEST工程名称显示</p>
        </div>
      </div>
      <div class="qzjx-card">
        <div class="card-form">
          <p class="mb20">请选择需要修改的节点：</p>
          <van-checkbox-group v-model="model.checked" class="mb20">
            <van-checkbox name="a" shape="square">现场安装</van-checkbox>
            <van-checkbox name="b" shape="square">安装自检</van-checkbox>
          </van-checkbox-group>
          <p class="mb10">请录入修改申请说明</p>
          <van-field v-model="model.mesage" rows="3" autosize label="" type="textarea" placeholder="请录入修改申请说明"
            show-word-limit />
        </div>
      </div>
      <!-- 审核意见 -->
      <v-popup-opinion v-model="showPinion" :selectUser="selectUser" ref="opinion" @save="saveOpinion('showPinion')">
      </v-popup-opinion>
      <f7-toolbar position="bottom" no-shadow class="fff" v-if="canEdit || canCheck">
        <template v-if="canEdit">
          <f7-button fill class="submit-btn" @click="fnSubmit()">提交</f7-button>
        </template>
        <template v-if="canCheck">
          <f7-button fill class="submit-btn plain-btn" @click="selectUser.comment='';showPinion = true">退回</f7-button>
          <f7-button fill class="submit-btn" @click="selectUser.comment='';showPinion = true">通过</f7-button>
        </template>
      </f7-toolbar>
    </f7-page>
  </template>
  
  <script>
  import Controller from "@/libs/framework/controller";
  export default class sInsp extends Controller {
    onBeforeInit() {
      this.urls = {
        model: "/app/equipment/eqmInstallNotify/queryInstallManageInfo",
      };
    }
    onInit() { }
    onBeforeQuery(type, conditions, params) { }
    onAfterQuery(type, isSuccess, result) {
      return result;
    }
  
    mixin() {
      return {
        props: {},
        data() {
          return {
            model: {
              checked: [],
  
            },
            canEdit: false,
            canCheck: true,
            selectUser: {
              selectComment: null,
              comment: null,
              comments: [],
              tran: [],
              activity: "",
              users: [],
            },
            showPinion: false,
          };
        },
        methods: {
          // 提交
          fnSubmit(){

          },
          saveOpinion() {
            // this.$util
            //   .getPromise("/equipment/eqmCase/saveDetects", {
            //     detects,
            //   })
            //   .then((r) => {
            //     if (r && r.success) {
                  
            //     } else {
            //     }
            //   }).catch(err => {
            //   });
          },
        },
      };
    }
  }
  </script>
  
  <style lang="less" scoped>
  @import url("../../../../assets/css/commonPage.less");
  
  .mb10 {
    margin-bottom: 10px;
  }
  
  .mb20 {
    margin-bottom: 20px;
  }
  
  .van-checkbox {
    margin-bottom: 10px;
  }
  
  .van-field {
    background-color: #F5F7FA;
  }
  </style>
  